<template>
	<view class="teacher-page">
		<view class="teacher-part">
			<teacherSynopsis  :teacherDate = " teacherDate "/>
		</view>
		<view class="teacher-code">
			<button type="primary" @click="createCode">生成教师邀请码</button>
		</view>
		<CreateQRcode  :mark="mark" :code="code" @saveCode="saveCode"  />
	</view>
</template>

<script>
  import  teacherSynopsis from './components/commonSynopsis.vue';
  import  CreateQRcode from '@/components/createQRcode/index.vue';
  export default{
	  data(){
		  return{
			  teacherDate:[
				  {
					  "image":"/static/image.png",
					  "name":"张红梅",
					  "solitaire":345,
					  "operation":365,
					  "photograph":46
				  }
			  ],
			  mark:true,
			  code:"A100091"
		  }
	  },
	  components:{
		  teacherSynopsis,
		  CreateQRcode
	  },
	  methods:{
		  createCode(){
			  this.mark=false;
		  },
		  saveCode(path){
			  this.mark=true;
		  }
	  }
  }
</script>

<style lang="scss" scoped>
	page,.teacher-page{
		width: 100%;
		height: 100%;
		display: flex;
		flex-direction: column;
		&>.teacher-part{
			flex: 8;
		}
		&>.teacher-code{
			flex: 2;
			display: flex;
			align-items: center;
			justify-content: center;
			&>button{
               	width: 85%;
               	height: 80upx;
               	font-size: 32upx;
               	border:none;
               	background: #409EFF; 				
			}
		}
	}
</style>
